home *** CD-ROM | disk | FTP | other *** search
/ Ancient Asian Sex Secrets / Ancient Asian Sex Secrets.iso / mac / ALLEYM_C.Dxr / 00101.ls < prev    next >
Encoding:
Text File  |  1997-04-30  |  7.1 KB  |  234 lines

  1. on enterFrame
  2.   global gDel, gTime, gDely, gX1, gX2, gShot, gPinList, gXBall, gYBall, gZBall, gBall, gAb, gNb, gpoint, gEBall, gHHList, gDDList, gTTList, gWWList, gBPList, gWPList, gDPList, gVPList, gDTList, gPHList, gPinSnd
  3.   set gHHList to list(320, 308, 332, 296, 320, 342, 284, 308, 332, 354)
  4.   set gDDList to list(-4, -4, -5, -5, -6, -6, -5, -4, -3, -2, -1, 0, 1, 2, 3, 4, 5, 6, 6, 5, 5, 4, 4)
  5.   set gTTList to list(5, 5, 5, 5, 4, 4, 4, 4, 4, 3, 3, 3, 3, 3, 2, 2, 2, 2, 2, 1, 1, 1, 1)
  6.   set gWWList to list(2, 8, 4, 6)
  7.   set gBPList to list(0, 0, 0, 0, 0, 0, 0, 0, 0, 0)
  8.   set gWPList to list(0, 0, 0, 0, 0, 0, 0, 0, 0, 0)
  9.   set gDPList to list(0, 0, 0, 0, 0, 0, 0, 0, 0, 0)
  10.   set gVPList to list(0, 0, 0, 0, 0, 0, 0, 0, 0, 0)
  11.   set gDTList to list(9, 9, 9, 9, 9, 9, 9, 9, 9, 9)
  12.   set gPHList to list(0, 0, 0, 0, 0, 0, 0, 0, 0, 0)
  13.   set gPinSnd to 1
  14.   set gEBall to integer(256 / gDely)
  15.   set gpoint to 0
  16.   set gAb to 1
  17.   set dH to KickPin(1, 1)
  18.   ApinDown(1, 1)
  19.   set gAb to gNb
  20.   RollBall(dH, 4)
  21.   set gBall to gBall + 1
  22.   set dH to KickPin(2, 3)
  23.   PinKPin(2, 3)
  24.   ApinDown(2, 3)
  25.   RollBall(dH, 8)
  26.   set gBall to gBall + 1
  27.   set dH to KickPin(4, 6)
  28.   PinKPin(4, 6)
  29.   ApinDown(4, 6)
  30.   RollBall(dH, 12)
  31.   set gBall to gBall + 1
  32.   set dH to KickPin(7, 10)
  33.   PinKPin(7, 10)
  34.   ApinDown(7, 10)
  35.   if gPinSnd = 1 then
  36.     set gPinSnd to 0
  37.     puppetSound("NULLDOWN.AIF")
  38.   end if
  39. end
  40.  
  41. on KickPin P1, P2
  42.   global gDel, gTime, gDely, gX1, gX2, gShot, gPinList, gGTR, gXBall, gYBall, gZBall, gBall, gAb, gNb, gpoint, gEBall, gHHList, gDDList, gTTList, gWWList, gBPList, gWPList, gDPList, gVPList, gDTList, gPHList, gPinSnd
  43.   set gNb to gAb
  44.   set bd to 0
  45.   set pin to P1
  46.   repeat while pin <= P2
  47.     set pX to getAt(gHHList, pin)
  48.     if gGTR > 0 then
  49.       set Dpb to 100
  50.     else
  51.       set Dpb to pX - gXBall
  52.     end if
  53.     if (abs(Dpb) < 12) and (getAt(gPinList, pin) = 0) then
  54.       if gPinSnd = 1 then
  55.         set gPinSnd to 0
  56.         puppetSound("PINDOWN.AIF")
  57.       end if
  58.       set Xd to getAt(gDDList, Dpb + 12)
  59.       setAt(gPinList, pin, gDel)
  60.       setAt(gPHList, pin, Dpb + pX)
  61.       setAt(gBPList, gNb, Dpb + pX)
  62.       setAt(gDPList, gNb, Xd)
  63.       setAt(gWPList, gNb, 14 + getAt(gWWList, gShot))
  64.       set Epin to integer(gEBall / 4)
  65.       set gEBall to gEBall - Epin
  66.       setAt(gVPList, gNb, Epin)
  67.       set kt to getAt(gTTList, Dpb + 12)
  68.       setAt(gDTList, pin, kt)
  69.       set gpoint to gpoint + 1
  70.       set gNb to gNb + 1
  71.     else
  72.       set Xd to 0
  73.     end if
  74.     set bd to bd - Xd
  75.     set pin to pin + 1
  76.   end repeat
  77.   return bd
  78. end
  79.  
  80. on PinKPin P1, P2
  81.   global gDel, gTime, gDely, gX1, gX2, gShot, gPinList, gXBall, gYBall, gZBall, gBall, gAb, gNb, gpoint, gHHList, gDDList, gTTList, gWWList, gBPList, gWPList, gDPList, gVPList, gDTList, gPHList
  82.   set bp to 1
  83.   repeat while bp < gAb
  84.     set pin to P1
  85.     set bd to 0
  86.     repeat while pin <= P2
  87.       set Xd to 0
  88.       set pX to getAt(gHHList, pin)
  89.       set bX to getAt(gBPList, bp)
  90.       set Dpb to pX - bX
  91.       set Wd to 5 + integer(getAt(gWPList, bp) / 2)
  92.       set Epin to getAt(gVPList, bp)
  93.       if (abs(Dpb) < Wd) and (getAt(gPinList, pin) = 0) and (Epin >= 4) then
  94.         if Dpb < -11 then
  95.           set Dpb to -11
  96.         end if
  97.         if Dpb > 11 then
  98.           set Dpb to 11
  99.         end if
  100.         set Epin to integer(Epin / 2)
  101.         setAt(gVPList, bp, Epin)
  102.         setAt(gVPList, gNb, Epin)
  103.         set Xd to getAt(gDDList, Dpb + 12)
  104.         setAt(gPinList, pin, gDel)
  105.         setAt(gPHList, pin, Dpb + pX)
  106.         setAt(gBPList, gNb, Dpb + pX)
  107.         setAt(gDPList, gNb, Xd)
  108.         setAt(gWPList, gNb, 14 + getAt(gWWList, gShot))
  109.         set kt to getAt(gTTList, Dpb + 12)
  110.         setAt(gDTList, pin, kt)
  111.         set gpoint to gpoint + 1
  112.         set gNb to gNb + 1
  113.       else
  114.         set Xd to 0
  115.       end if
  116.       set bd to bd - Xd
  117.       set pin to pin + 1
  118.     end repeat
  119.     set bX to bX + bd + getAt(gDPList, bp)
  120.     setAt(gBPList, bp, bX)
  121.     set bp to bp + 1
  122.   end repeat
  123.   set gAb to gNb
  124. end
  125.  
  126. on ApinDown P1, P2
  127.   global gDel, gPinList, gDTList, gPHList
  128.   set pdList to list("A1.BMP", "B1.BMP", "C1.BMP", "D1.BMP", "E1.BMP", "A2.BMP", "B2.BMP", "C2.BMP", "D2.BMP", "E2.BMP")
  129.   set down to 0
  130.   repeat while down < 2
  131.     set pn to P1
  132.     repeat while pn <= P2
  133.       set pSprt to 24 - pn
  134.       puppetSprite(pSprt, 1)
  135.       if getAt(gPinList, pn) = gDel then
  136.         set the visible of sprite (46 - pn) to 1
  137.         set downType to getAt(gDTList, pn)
  138.         set the locH of sprite pSprt to getAt(gPHList, pn)
  139.         set the locV of sprite pSprt to the locV of sprite pSprt + 6
  140.         set kc to integer(downType + (down * 5))
  141.         set kc to the number of member getAt(pdList, kc)
  142.         set the castNum of sprite pSprt to kc
  143.       end if
  144.       set pn to pn + 1
  145.     end repeat
  146.     updateStage()
  147.     set down to down + 1
  148.   end repeat
  149. end
  150.  
  151. on exitFrame
  152.   global gCase, gNo, gDel, gpoint, gSet, gStrike, gBonus, gRecord, gSum, gMinList, gAlley, gVALUE, gACC, gCheer, gGirl
  153.   set gCheer to "ASWEEP"
  154.   if (gDel = 1) and (gpoint = 10) then
  155.     set gStrike to 1
  156.     set gSet to 2
  157.   else
  158.     set gStrike to 0
  159.     if gBonus = 1 then
  160.       set gSet to 2
  161.     else
  162.       set gSet to gDel
  163.     end if
  164.   end if
  165.   set the visible of sprite 46 to 0
  166.   puppetSprite(46, 0)
  167.   set gCase to "DOWN"
  168.   set gNo to 1
  169.   updateStage()
  170.   gflag()
  171.   keepSum()
  172.   scoreDisp()
  173.   if gGirl = 1 then
  174.     getCheer()
  175.   end if
  176.   cursor(-1)
  177.   go(gCheer)
  178. end
  179.  
  180. on keepSum
  181.   global gSum3, gSum, gFrame, gSumList, gScore, gAlley
  182.   set gSum to gSum3
  183. end
  184.  
  185. on getCheer
  186.   global gDel, gFrame, gpoint, gPointLast, gStrike, gGTR, gAlley, gStartMov, gCheer, gChMov, gFINAL, gColor
  187.   set ChMovList to list("AGC31.MOV", "AGC32.MOV", "AGC33.MOV", "AGC34.MOV", "AGC35.MOV", "AGC11.MOV", "AGC12.MOV", "AGC13.MOV", "AGC14.MOV", "AGC15.MOV", "AGC21.MOV", "AGC22.MOV", "AGC23.MOV", "AGC24.MOV", "AGC25.MOV")
  188.   set girlmList to list("AGC31", "AGC32", "AGC33", "AGC34", "AGC35", "AGC11", "AGC12", "AGC13", "AGC14", "AGC15", "AGC21", "AGC22", "AGC23", "AGC24", "AGC25")
  189.   set movOK to 0
  190.   set kag to integer((gAlley - 1) * 5)
  191.   if gStrike = 1 then
  192.     set gChMov to getAt(ChMovList, 1 + kag)
  193.     set gCheer to getAt(girlmList, 1 + kag)
  194.     set movOK to 1
  195.   else
  196.     if (gDel = 2) and (gFrame < gFINAL) and ((gpoint + gPointLast) = 10) then
  197.       set gChMov to getAt(ChMovList, 2 + kag)
  198.       set gCheer to getAt(girlmList, 2 + kag)
  199.       set movOK to 1
  200.     else
  201.       if (gDel = 2) and ((gpoint + gPointLast) < 2) then
  202.         set gChMov to getAt(ChMovList, 3 + kag)
  203.         set gCheer to getAt(girlmList, 3 + kag)
  204.         set movOK to 1
  205.       else
  206.         if (gDel = 2) and ((gpoint + gPointLast) < 4) then
  207.           set gChMov to getAt(ChMovList, 4 + kag)
  208.           set gCheer to getAt(girlmList, 4 + kag)
  209.           set movOK to 1
  210.         else
  211.           if gGTR > 0 then
  212.             set gChMov to getAt(ChMovList, 5 + kag)
  213.             set gCheer to getAt(girlmList, 5 + kag)
  214.             set movOK to 1
  215.           end if
  216.         end if
  217.       end if
  218.     end if
  219.   end if
  220.   if movOK = 1 then
  221.     repeat while soundBusy(1) = 1
  222.       nothing()
  223.     end repeat
  224.     puppetSound(0)
  225.     preLoadCast(gChMov)
  226.     if gColor >= 16 then
  227.       set the directToStage of cast gChMov to 1
  228.     else
  229.       set the directToStage of cast gChMov to 0
  230.     end if
  231.     set gStartMov to 1
  232.   end if
  233. end
  234.